package com.czh.dao;

import com.czh.pojo.Account;
import com.czh.pojo.test;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;

public interface AccountDao {

    List<Account> findAll(@Param("id")Integer id,@Param("name")String name);

    @Select("SELECT * FROM account WHERE `name` = #{name}")
    Account findByName(String name);

//    @Param()设置参数命名
    Account findById(@Param("id") Integer i);

    List<Account> finByIdList(@Param("listId")int[] listId);

    //多表查id
    Account tableById(Integer id);

    //多表查全部
    Account tableList(Integer id);

    //添加
    boolean insertUser(Account account);

    //删除
    boolean deleteUserId(Integer id);

    //修改
    boolean updateUser(Account account);

    //分步查询
    test releaseSelect(String name);


}
